<template>
  <div class="pro">
    <CartHeader></CartHeader>
    <CartItems v-show="Items.length>0"></CartItems>
    <Empty v-show="Items.length==0"></Empty>
    <GuessLike></GuessLike> 
    <FooterLink></FooterLink>
   
  </div>
</template>
<script>
import GuessLike from "./GuessLike"
import Empty from "./Empty"
import CartItems from "./CartItems"
import FooterLink from "../common/FooterLink"
import CartHeader from "./CartHeader"
export default {
  components:{
    GuessLike,
    Empty,
    CartItems,
    FooterLink,
    CartHeader
  },
  data(){
    return {
      text : "购物车"
    }
  },
  computed:{
    Items(){
      console.log(this.$store.state.cartItems)
      return this.$store.state.cartItems;
    }
  }
}
</script>
<style lang="less" scoped>
.pro{
  background:#f0f0f0;
  padding-bottom:.49rem;
}
</style>
